import request from "@/util/request";

// 搜索好友
export const getFriends = (pn) => {
    return request({
        url: `/applet/userContact/findByPhoneOrName/${pn}`,
        method: "GET",
    });
}

// 添加好友
export const addFriends = (data) => {
    return request({
        url: "/applet/userContact/apply",
        method: "post",
        data
    });
}

//获取好友列表
export const getFriendsList = (query) => {
    return request({
        url: "/applet/userContact/list",
        method: "get",
        params: query
    });
}

// 消息列表
export const getMessageList = () => {
    return request({
        url: "/applet/infoNotice/list",
        method: "get",
    });
}


// 审核好友申请
export const auditFriend = (data) => {
    return request({
        url: "/applet/userContact/audit",
        method: "post",
        data
    });
}
